
package org.darcy.model;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;

import org.darcy.entity.BizArticle;
import org.darcy.entity.BizComment;
import org.darcy.entity.SysUser;
import org.darcy.framework.model.PageParam;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

@ApiModel("文章评论: BizCommentModel")
@Getter
@Setter
public class BizCommentModel extends PageParam implements Serializable{
	
	private static final long serialVersionUID = 1L;
     
    @Id
    @Column(name = "ID")
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @ApiModelProperty(value="")
	private Long id;
	
    @ApiModelProperty(value="被评论的文章或者页面的ID")
	private Long sid;
	
    @ApiModelProperty(value="评论人的ID")
	private Long userId;
	
    @ApiModelProperty(value="父级评论的id")
	private Long pid;
	
    @ApiModelProperty(value="评论人的QQ（未登录用户）")
	private String qq;
	
    @ApiModelProperty(value="评论人的昵称（未登录用户）")
	private String nickname;
	
    @ApiModelProperty(value="评论人的头像地址")
	private String avatar;
	
    @ApiModelProperty(value="评论人的邮箱地址（未登录用户）")
	private String email;
	
    @ApiModelProperty(value="评论人的网站地址（未登录用户）")
	private String url;
	
    @ApiModelProperty(value="评论的状态")
	private String status;
	
    @ApiModelProperty(value="评论时的ip")
	private String ip;
	
    @ApiModelProperty(value="经度")
	private String lng;
	
    @ApiModelProperty(value="纬度")
	private String lat;
	
    @ApiModelProperty(value="评论时的地址")
	private String address;
	
    @ApiModelProperty(value="评论时的系统类型")
	private String os;
	
    @ApiModelProperty(value="评论时的系统的简称")
	private String osShortName;
	
    @ApiModelProperty(value="评论时的浏览器类型")
	private String browser;
	
    @ApiModelProperty(value="评论时的浏览器的简称")
	private String browserShortName;
	
    @ApiModelProperty(value="评论的内容")
	private String content;
	
    @ApiModelProperty(value="备注（审核不通过时添加）")
	private String remark;
	
    @ApiModelProperty(value="支持（赞）")
	private Integer support;
	
    @ApiModelProperty(value="反对（踩）")
	private Integer oppose;
	
    @ApiModelProperty(value="添加时间")
	private Date createTime;
	
    @ApiModelProperty(value="更新时间")
	private Date updateTime;
	
    
    /**
   	 * model类转化为mybatis plus 查询条件
   	 */
   	public QueryWrapper<BizComment> buildWrapper() {
   		QueryWrapper<BizComment> p = new QueryWrapper<BizComment>();
   		return p;
   	}
   	
    @ApiModelProperty(value="上一条评论")
    private BizComment parent;
    
    @ApiModelProperty(value="对应的文章")
    private BizArticle article;
    
    @ApiModelProperty(value="用户")
    private SysUser user;
    


}
